package com.zswlib.netease.webapp.rmi;

import com.sun.org.apache.xpath.internal.SourceTree;
import com.zswlib.netease.webapp.po.Author;

import java.net.MalformedURLException;
import java.rmi.AlreadyBoundException;
import java.rmi.Naming;
import java.rmi.RemoteException;
import java.rmi.server.UnicastRemoteObject;

public class AuthorRMIImpl extends UnicastRemoteObject implements AuthorRMI{

    public AuthorRMIImpl() throws RemoteException{
        super();
    }

    public Author getAuthor(String username, String password) throws RemoteException {
        Author a = new Author();
//        a.setUsername(username);
//        a.setPassword(password);
        a.setUsername("fannie");
        a.setPassword("19961113");
        System.out.println("进来一个请求：username="+username+", password="+password);
        return a;
    }

}
